Skip to content

Conversation

@avilagaston9
Copy link
Contributor

Motivation

Currently, our integration tests use default fee vault addresses, and to run the tests with custom ones, we need to pass them through env vars.

Description

  • Update the integration tests to fetch the current addresses via RPC.

Closes None

@github-actions
Copy link

github-actions bot commented Nov 4, 2025

Lines of code report

Total lines added: 62
Total lines removed: 0
Total lines changed: 62

Detailed view
+----------------------------------------------------+-------+------+
| File                                               | Lines | Diff |
+----------------------------------------------------+-------+------+
| ethrex/crates/l2/networking/rpc/clients.rs         | 127   | +16  |
+----------------------------------------------------+-------+------+
| ethrex/crates/l2/networking/rpc/l2/fees.rs         | 200   | +35  |
+----------------------------------------------------+-------+------+
| ethrex/crates/l2/networking/rpc/rpc.rs             | 217   | +2   |
+----------------------------------------------------+-------+------+
| ethrex/crates/networking/rpc/clients/eth/errors.rs | 347   | +9   |
+----------------------------------------------------+-------+------+

@avilagaston9 avilagaston9 marked this pull request as ready for review November 4, 2025 17:32
@avilagaston9 avilagaston9 requested a review from a team as a code owner November 4, 2025 17:32
Copilot AI review requested due to automatic review settings November 4, 2025 17:32
@avilagaston9 avilagaston9 moved this to In Review in ethrex_l2 Nov 4, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for retrieving the L1 fee vault address dynamically from the L2 RPC server instead of relying on environment variables. The change enables the system to handle optional fee vaults (returning None when not configured) and removes the need for the INTEGRATION_TEST_SKIP_BASE_FEE_VAULT_CHECK environment variable.

  • Added new RPC method ethrex_getL1FeeVaultAddress to retrieve L1 fee vault address
  • Changed fee vault functions to return Option<Address> instead of Address to support optional vaults
  • Refactored test code to fetch vault addresses dynamically and skip assertions when vaults are not configured

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
crates/networking/rpc/clients/eth/errors.rs Added error types for the new L1 fee vault address RPC method
crates/l2/networking/rpc/rpc.rs Registered the new ethrex_getL1FeeVaultAddress RPC method handler
crates/l2/networking/rpc/l2/fees.rs Implemented GetL1FeeVaultAddress handler following existing patterns for fee vault retrieval
crates/l2/networking/rpc/clients.rs Added client function to call the new RPC method and updated return types to Option<Address>
crates/l2/tests/tests.rs Refactored tests to dynamically fetch vault addresses and handle optional vaults, removed hardcoded addresses
.github/workflows/pr-main_l2.yaml Removed INTEGRATION_TEST_SKIP_BASE_FEE_VAULT_CHECK environment variable from CI workflows

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

L2 Rollup client

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

3 participants